<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:h="http://java.sun.com/jsf/html"

      xmlns:p="http://primefaces.org/ui"
      xmlns:f="http://java.sun.com/jsf/core"
      xmlns:ui="http://java.sun.com/jsf/facelets">

    <h:head>
        <link type="text/css" rel="stylesheet" href="resources/css/default.css" />
        <link type="text/css" rel="stylesheet" href="default.css" />
       
            
    </h:head>

    <h:body>

        <div id="container">

            <div id="cabecalho">
                <h:graphicImage library="img" name="logo.png" styleClass="logo" />
            </div>

            <div id="conteudo">


                <form id="login" method="post" action="${request.contextPath}/j_spring_security_check">
                    <p:fieldset legend="Dados do Login" styleClass="fieldsetlogin" >
                        <h:panelGrid columns="2"  styleClass="fieldsetcomponentes">
                            <h:outputLabel for="j_username" value="Login: *" />
                            <p:inputText id="j_username" required="true" 
                                         size="40">

                            </p:inputText>
                            <h:outputLabel for="j_password" value="Senha: * " />
                            <p:password  id="j_password" required="true"
                                        size="40">

                            </p:password>
                          
                            <h:commandButton value="Entrar"/>
                        </h:panelGrid>

                    </p:fieldset>
                    <h:panelGroup styleClass="fieldsetcomponentes" rendered="#{!empty param.login_error}">
                        <span> Erro ao efetuar Login, verifique login e senha!!!</span><br />
                        <br/>
                        <!--Motivo: #{SPRING_SECURITY_LAST_EXCEPTION.message}-->
                    </h:panelGroup>
                    <script>
                        document.getElementById("login").j_username.value = "#{SPRING_SECURITY_LAST_USERNAME}";


                    </script>
                </form>
            </div>
            
        </div>
        <div id="rodapeFundo">
           
                <h3 style="text-align: center;line-height:100px;" Class="rotulosLogin"> Copyright®2014 - Tmd Soluções. Todos os direitos reservados.</h3>
           
        </div>
    </h:body>

</html>